fix: add short-name package for E1 judge env#71
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a22d596920
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
| # Optional Hub environment name override (defaults to pyproject.toml name) | ||
| # Usage: make hub-deploy E=network-logs NAME=sv-env-network-logs-judge | ||
| # Usage: make hub-deploy E=network-logs NAME=sv-netlogs-judge |
There was a problem hiding this comment.
Use the short-package path in hub-deploy usage example
The new usage comment points to make hub-deploy E=network-logs NAME=sv-netlogs-judge, but the deploy recipe builds from environments/sv-env-$(E), so that command still packages the old sv-env-network-logs distribution instead of sv-env-netlogs-judge. Following this instruction can reintroduce the package-metadata mismatch this commit is trying to avoid and lead to failed installs/runs for the short ID.
Useful? React with 👍 / 👎.
|
|
||
| if logger and logger.enabled: | ||
| logger.log_environment_init( | ||
| environment_name="sv-env-network-logs-judge", |
There was a problem hiding this comment.
Align logged environment name with the short alias
The short-name entrypoint wraps this loader, but log_environment_init still emits environment_name="sv-env-network-logs-judge" here before the wrapper renames the returned env object. In runs where rollout logging is enabled, sv-netlogs-judge executions will be recorded under the old ID, which can mix telemetry across env IDs and make experiment attribution unreliable.
Useful? React with 👍 / 👎.
|
@claude review |
|
Claude finished @intertwine's task in 2m 37s —— View job Code Review
SummaryThe approach is sound — publishing a short-name package to work around Prime's 20-character Kubernetes label truncation bug is the right move, and the wrapper pattern in Issues🔴 P1 — Makefile comment still points to the wrong source env
# Usage: make hub-deploy E=network-logs NAME=sv-netlogs-judgeThe The correct invocation is: # Usage: make hub-deploy E=netlogs-judgeNo 🟡 P2 — Telemetry is logged under the old ID before the wrapper renames it
logger.log_environment_init(
environment_name="sv-env-network-logs-judge", # ← logged here
...
)
env = _load_environment(**kwargs)
env.name = SHORT_ENV_ID # ← renamed after the fact
env.env_id = SHORT_ENV_IDWhen a The simplest fix is to accept the env name as an optional parameter in # sv_env_network_logs_judge.py
def load_environment(
...
env_name: str = "sv-env-network-logs-judge",
...
):
...
logger.log_environment_init(environment_name=env_name, ...)
return vf.SingleTurnEnv(name=env_name, ...)# sv_netlogs_judge.py
def load_environment(**kwargs):
kwargs.setdefault("env_name", SHORT_ENV_ID)
return _load_environment(**kwargs)Minor PointsTest file included in the wheel ( PR body test-plan path typo
Duplicate What's Working Well
|
- wire env_name through the short judge loader for consistent telemetry - rename the short-package implementation module to avoid collisions - fix hub-deploy docs and exclude tests from the wheel
|
@claude re-review |
|
Claude finished @intertwine's task in 1m 46s —— View job Re-review
SummaryAll P1 and P2 issues from the previous review have been fixed. The two remaining items are minor stale references in the research doc. This PR is ready to merge. Previous Issues — All Resolved ✅P1 — Makefile comment ( # Usage: make hub-deploy E=netlogs-judgeFixed. The comment now correctly points to P2 — Telemetry logged under old ID Test file in wheel Test coverage for the fix Remaining Minor ItemsStale status checklist in research doc ( Two items are out of date:
Neither blocks merge, but worth tidying up. Fix this → Pre-existing: REPO_ROOT = str(Path(__file__).resolve().parents[2])When installed as a wheel, What's Working WellThe implementation is clean and the test suite is comprehensive. In particular, |
Summary
environments/sv-env-netlogs-judgeconfigs/rl/e1_judge.tomltointertwine/sv-netlogs-judgesv-env-network-logs-judgeWhy
Prime truncates long environment names when deriving Kubernetes labels. The original judge env name truncates to
sv-env-network-logs-, which is invalid because it ends with-. A simple Hub rename was not enough because Prime also expects the installed distribution metadata to match the short name.This PR publishes the judge variant as a real short-name package (
sv-netlogs-judge) so hosted RL runs can both install and launch cleanly.Test Plan
pytest environments/sv-env-netlogs-judge/sv_netlogs_judge_test.py -qintertwine/sv-netlogs-judgev0.2.17 and verified Prime integration action succeedsi5fvjomdr3yjn3pg6y7x3nu8Notes
intertwine/svbench-e1/runs/bhsxeoivintertwine-ai/security-verifiers-e1viaE1_HF_REPOfor hosted dataset loading